@width: 800px;
@color: #a88ae9;

.todos {
    position: relative;
    width: 100%;
    min-height: 100vh;
    background-color: #d1d1f8;

    .oper_wrap {
        position: fixed;
        top: 0;
        left: 50%;
        transform: translateX(-50%);
        width: @width;
        height: 100vh;

        .oper {
            position: absolute;
            z-index: 10;
            top: 220px;
            right: -45px;
            width: 50px;
            height: 160px;
            display: flex;
            flex-direction: column;
            justify-content: space-between;
            align-items: center;

            .create,
            .clear,
            .back_home {
                font-size: 32px;
                cursor: pointer;
                transition: font-size 0.3s;

                &:hover {
                    font-size: 36px;
                    transition: font-size 0.3s;
                }
            }
        }
    }

    .wrap {
        position: relative;
        width: @width;
        min-height: 100vh;
        margin: auto;
        box-sizing: border-box;
        padding-top: 80px;
        background-color: rgba(255, 255, 255, 0.3);
    }

    .title {
        font-family: Alimama_ShuHeiTi_Bold;
        text-align: center;
        height: 30px;
        line-height: 30px;
        font-size: 24px;
        font-weight: bold;
        color: @color;
    }

    .todo_ul {
        width: 600px;
        margin: auto;
        display: flex;
        flex-direction: column;
        gap: 20px;
        margin-top: 20px;

        li {
            position: relative;
            box-sizing: border-box;
            padding: 15px;
            padding-right: 40px;
            border: 2px solid #f47a7a;
            border-radius: 6px;

            .todo_title,
            .detail,
            .pre_date {
                span {
                    color: @color;
                    font-weight: bold;
                    font-family: Alimama_ShuHeiTi_Bold;
                    font-size: 16px;
                }
            }
            .detail {
                word-break: break-all;
            }
            .detail,
            .pre_date {
                margin-top: 10px;
            }

            .todone,
            .del {
                position: absolute;
                right: 10px;
                font-size: 28px;
                cursor: pointer;
                display: none;
            }
            .todone {
                top: 5px;
            }
            .del {
                top: 50px;
            }

            &:hover {
                box-shadow: 0 0 2px 2px #f47a7a54;

                .todone,
                .del {
                    display: block;
                }
            }

            &.done {
                border: 2px solid #76ed76;

                &:hover {
                    box-shadow: 0 0 2px 2px #76ed7663;
                }
            }

            &:nth-last-child(1) {
                margin-bottom: 20px;
            }
        }
    }

    .bounced {
        position: fixed;
        z-index: 10;
        top: 0;
        left: 0;
        width: 0;
        height: 0;
        background-color: rgba(0, 0, 0, 0.7);
        overflow: hidden;
        display: flex;
        justify-content: center;
        align-items: center;
        transition: width 0.8s, height 0.8s;

        &.edit {
            width: 100%;
            height: 100vh;
            transition: width 0.8s, height 0.8s;
        }

        .edit_area {
            position: relative;
            width: 315px;
            background-color: rgba(255, 255, 255, 0.8);
            border-radius: 6px;
            box-sizing: border-box;
            padding-top: 10px;
            text-align: center;

            .head {
                font-family: Alimama_ShuHeiTi_Bold;
                text-align: center;
                height: 30px;
                line-height: 30px;
                font-size: 24px;
                font-weight: bold;
                color: @color;
            }

            .task_title,
            .expect_date {
                display: flex;
                align-items: center;
                width: 256px;
                margin: auto;
                gap: 10px;
                margin-top: 20px;

                span {
                    color: @color;
                    font-weight: bold;
                    font-family: Alimama_ShuHeiTi_Bold;
                    font-size: 16px;
                }

                .inp_title,
                .inp_date {
                    width: 180px;
                    height: 32px;
                    background-color: transparent;
                    border: 1px solid #bea9ec;
                    border-radius: 4px;
                    box-sizing: border-box;
                    padding: 0 5px;
                    letter-spacing: 1px;

                    &:focus {
                        box-shadow: 0 0 2px 2px #a88ae945;
                    }
                }

                .inp_date {
                    width: 163px;
                }
            }

            .task_content {
                display: flex;
                width: 256px;
                margin: auto;
                gap: 10px;
                margin-top: 20px;

                span {
                    color: @color;
                    font-weight: bold;
                    font-family: Alimama_ShuHeiTi_Bold;
                    font-size: 16px;
                }

                .inp_content {
                    width: 180px;
                    height: 188px;
                    background-color: transparent;
                    border: 1px solid #bea9ec;
                    border-radius: 4px;
                    box-sizing: border-box;
                    padding: 10px;
                    letter-spacing: 1px;
                    resize: none;
                    word-break: break-all;

                    &:focus {
                        box-shadow: 0 0 2px 2px #a88ae945;
                    }
                }
            }

            .submit {
                width: 100px;
                height: 30px;
                text-align: center;
                line-height: 30px;
                border: 1px solid #bea9ec;
                margin-top: 20px;
                margin-bottom: 15px;
                border-radius: 6px;
                cursor: pointer;
                user-select: none;
                -webkit-user-select: none;

                &:hover {
                    box-shadow: 0 0 2px 2px #a88ae945;
                }
            }
        }
    }
}
